package adavance.socket;

import java.io.IOException;
import java.net.ServerSocket;
import java.net.Socket;

/**
 * @author oldliu
 * @since 1.0
 */
public class GaojiFileServer {
    public static void main(String[] args) {
        try {
            ServerSocket st=new ServerSocket(8001);
            System.out.println("服务器启动成功，监听在8001端口");
            while (true){
                final Socket s = st.accept();
                //new FileSendThread(s).start();
                new FileSendThread2(s).start();
            }
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
}
